Efficient Top-Down Computation of Queries under the Well-Founded Semantics
نویسندگان
چکیده
The well-founded model provides a natural and robust semantics for logic programs with negative literals in the bodies of rules. Although various procedural semantics have been proposed for query evaluation under the well-founded semantics, the practical issues of implementation for eeective and eecient computation of queries have been rarely discussed. This paper investigates two major implementation issues of query evaluation under the well-founded semantics, namely (a) to ensure that negative literals be resolved only after their positive counterparts have been completely evaluated, and (b) to detect and handle potential negative loops. We present eecient incremental algorithms for maintaining positive and negative dependencies among subgoals in a top-down evaluation. Both completely evaluated subgoals and potential negative loops are detected by inspecting the dependency information of a single subgoal. Our implementation can be viewed as an eeective successor to SLDNF resolution, extending Prolog computation in a natural and smooth way.
منابع مشابه
Enhancing global SLS-resolution with loop cutting and tabling mechanisms
Global SLS-resolution is a well-known procedural semantics for top-down computation of queries under the well-founded model. It inherits from SLDNF-resolution the linearity property of derivations, which makes it easy and efficient to implement using a simple stack-based memory structure. However, like SLDNF-resolution it suffers from the problem of infinite loops and redundant computations. To...
متن کاملLinear Tabulated Resolutions for the Well-Founded Semantics
Global SLS-resolution and SLG-resolution are two representative mechanisms for top-down evaluation of the well-founded semantics of general logic programs. Global SLS-resolution is linear but suffers from infinite loops and redundant computations. In contrast, SLG-resolution resolves infinite loops and redundant computations by means of tabling, but it is not linear. The distinctive advantage o...
متن کاملStabel Model Implementation of Layer Supported Models by Program Transformation
• For practical applications, availability of a top-down query-driven procedure is most convenient for ease of use and efficient computation of answers, when employing Logic Programs as knowledge bases • 2-valued semantics for Normal Logic Programs (NLPs) allowing top-down query-solving is highly desirable, but the Stable Models semantics (SM) does not permit it, for lack of the " relevance " p...
متن کاملStable Model implementation of Layer Supported Models by program transformation
For practical applications, the use of top-down query-driven proofprocedures is convenient for an efficient use and computation of answers using Logic Programs as knowledge bases. A 2-valued semantics for Normal Logic Programs (NLPs) allowing for top-down query-solving is thus highly desirable, but the Stable Models semantics (SM) does not allow it, for lack of the relevance property. To overco...
متن کاملStable versus Layered Logic Program Semantics
For practical applications, the use of top-down query-driven proofprocedures is convenient for an efficient use and computation of answers using Logic Programs as knowledge bases. Additionally, abductive reasoning on demand is intrinsically a top-down search method. A 2-valued semantics for Normal Logic Programs (NLPs) allowing for top-down query-solving is thus highly desirable, but the Stable...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
- J. Log. Program.
دوره 24 شماره
صفحات -
تاریخ انتشار 1995